﻿<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"
						 assembly="MusicStore.Entities"
						 namespace="MusicStore.Entities">
	<class name="Album" table="Albums">
		<id name="Id" column="Id" type="int">
			<generator class="identity" />
		</id>
		<property name="Title" column="Title" type="string" />
		<property name="Author" column="Author" type="string" />
		<property name="Label" column="Label" type="string" />
		<property name="Genre" column="Genre" type="string" />
		<property name="PublicationDate" column="PublicationDate" type="DateTime" />
		<property name="Note" column="Note" type="string" />
		<bag name="Tracks" table="Tracks">
			<key column="Id"/>
			<composite-element class="Track">
				<property name="Number" column="Number" type="int" />
				<property name="Title" column="Title" type="string" />
				<property name="Duration" column="Duration" type="string" />
			</composite-element>
		</bag>
	</class>
</hibernate-mapping>